<div class="panel panel-info">
    <!--面板标题-->
    <div class="panel-heading">
        <h3 class="panel-title">信件列表</h3>
    </div>

    <div class="panel-body">
        <div id="toolbar">
            <button id="btnLook" class="btn btn-default">
                <span class="glyphicon glyphicon-eye-open"></span>
            </button>
            <button id="btnDel" class="btn btn-default">
                <span class="glyphicon glyphicon-minus"></span>
            </button>
            <button id="btnRefresh" class="btn btn-default">
                <span class="glyphicon glyphicon-refresh"></span>
            </button>
        </div>
        <table id="table"
               data-toggle="table"
               data-height="428"
               data-pagination="true"
               data-page-list="[7, 15, 20, 30]"
               data-page-size="7"
               data-search="true"
               data-show-columns="true"
               data-click-to-select="true"
               data-striped="true"
               data-id-field="id"
               data-toolbar="#toolbar"
               data-url="toLetterList">
            <thead>
            <tr>
                <th data-field="state" data-checkbox="true"></th>
                <th data-field="index" data-formatter="indexFormatter" >序号</th>
                <th data-field="userName">发件人</th>
                <th data-field="contactWay">联系方式</th>
                <th data-field="viewStatus" data-formatter="letterStatusFormatter">查阅状态</th>
                <th data-field="gmtCreate" data-formatter="formatDateTime">创建时间</th>
                <th data-field="gmtModified" data-formatter="formatDateTime">修改时间</th>
            </tr>
            </thead>
        </table>
    </div>
</div>
<!-- 模态框（Modal） -->
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
    <div class="modal-dialog" style="width:70%">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">
                    &times;
                </button>
                <h4 class="modal-title" id="myModalLabel">
                    查看信件
                </h4>
            </div>
            <div class="modal-body">
                <form class="form-horizontal" role="form" id="letterForm">
                    <div class="form-group">
                        <label for="userName" class="col-md-2 control-label">发件人</label>
                        <div class="col-md-9">
                            <input ng-model="letter.userName" id="userName" name="userName" type="text" class="form-control" readonly>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="contactWay" class="col-md-2 control-label">联系方式</label>
                        <div class="col-md-9">
                            <input ng-model="letter.contactWay" id="contactWay" name="contactWay" type="text" class="form-control" readonly>
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="content" class="col-md-2 control-label">信件内容</label>
                        <div class="col-md-9">
                            <textarea ng-model="letter.content"  name="content" id="content" class="form-control" rows="10" readonly></textarea>
                        </div>
                    </div>
                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭
                </button>
            </div>
        </div><!-- /.modal-content -->
    </div><!-- /.modal -->
</div>
<link rel="stylesheet" type="text/css" href="plugins/bs-table/bootstrap-table.css" />
<script src="plugins/bs-table/bootstrap-table.js"></script>
<script src="plugins/bs-table/bootstrap-table-zh-CN.js"></script>
<script src="plugins/nice-validator/jquery.validator.min.js?local=zh-CN"></script>
<script src="js/admin/letterList.js"></script>
